{extend name='index/base' /}

{block name='main'}
<body>
<article class="page-container">
    <form action="{:url('admin/Goldentry/dokoukuang')}" method="post" class="form form-horizontal" id="kk" enctype="multipart/form-data">
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>扣款账号(手机号)：</label>
            <div class="formControls col-xs-8 col-sm-9">
                <input type="text" class="input-text" value="" id="tel" placeholder="" name="tel">
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>真实姓名：</label>
            <div class="formControls col-xs-8 col-sm-9">
                <input type="text" class="input-text" value="" placeholder="" id="name" name="name">
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>账户余额：</label>
            <div class="formControls col-xs-8 col-sm-9">
                <input type="text" class="input-text" id="balance" value="" placeholder="" name="money">
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>冻结资金：</label>
            <div class="formControls col-xs-8 col-sm-9">
                <input type="text" class="input-text" id="dj" value="" placeholder="" name="money">
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>扣款金额：</label>
            <div class="formControls col-xs-8 col-sm-9">
                <input type="text" class="input-text" value="" placeholder="" name="money">
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>扣款备注：</label>
            <div class="formControls col-xs-8 col-sm-9">
                <textarea name="remake" cols="" rows="" class="textarea"  placeholder="说点什么...最少输入10个字符" ></textarea>
                <!--<p class="textarea-numberbar"><em class="textarea-length">0</em>/100</p>-->
            </div>
        </div>
        <div class="row cl">
            <div class="col-xs-8 col-sm-9 col-xs-offset-4 col-sm-offset-3">
                <input class="btn btn-primary radius" type="button" onclick="modaldemo()" value="&nbsp;&nbsp;提交&nbsp;&nbsp;">
            </div>
        </div>
        <div id="modal-demo" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
            <div class="modal-dialog">
                <div class="modal-content radius">
                    <div class="modal-header">
                        <!--<h3 class="modal-title">对话框标题</h3>-->
                        <h3 class="modal-title">请输入密码</h3>
                        <a class="close" data-dismiss="modal" aria-hidden="true" href="javascript:void();">×</a>
                    </div>
                    <div class="modal-body">
                        <!--<p>对话框内容…</p>-->
                        <input id="pwd" class="input-text" type="password" name="pwd">
                    </div>
                    <div class="modal-footer">
                        <button class="btn btn-primary" id="sure" data-id="" >确定</button>
                        <button class="btn" data-dismiss="modal" aria-hidden="true">关闭</button>
                    </div>
                </div>
            </div>
        </div>
    </form>
</article>
</body>
</html>
{/block}


{block name='my'}
<!--请在下方写此页面业务相关的脚本-->
<script type="text/javascript" src="/static/admin/lib/My97DatePicker/4.8/WdatePicker.js"></script>
<script type="text/javascript" src="/static/admin/lib/jquery.validation/1.14.0/jquery.validate.js"></script>
<script type="text/javascript" src="/static/admin/lib/jquery.validation/1.14.0/validate-methods.js"></script>
<script type="text/javascript" src="/static/admin/lib/jquery.validation/1.14.0/messages_zh.js"></script>
<script type="text/javascript">
    function modaldemo(){
        $("#modal-demo").modal("show");
        return false;

    }
    $('#sure').click(function () {
        $('#kk').submit();
    })
    $(function(){
        $('.skin-minimal input').iCheck({
            checkboxClass: 'icheckbox-blue',
            radioClass: 'iradio-blue',
            increaseArea: '20%'
        });


    });

    $('#tel').keyup(function () {
        var $tel=$(this).val();
        var len=$tel.length;
        if(len==11){
            $.ajax({
                type:'get',
                url:'/admin/Goldentry/findmoney?tel='+$tel,
                dataType:'json',
                success:function (data) {
//                console.log(data);
                    $('#name').val(data.name);
                    $('#balance').val(data.balance);
                    $('#dj').val(data.dj);
                },
                error:function () {
                }
            })
        }
    })

</script>
<!--/请在上方写此页面业务相关的脚本-->
{/block}
